package com.oa.core.enumm;

/**
 * 错误码枚举类
 * @author syb
 * date 2019/2/12
 */
public enum CodeEnum {

    CODES_401(401,"身份验证失败"),
    CODES_402(402,"登录过期"),
    CODES_403(403,"没有访问权限"),

    SYSTEM_UNKNOWN_ERROR(500,"系统未知错误"),
    DATA_IS_EMPTY(501,"查询数据为空"),
    PARAMETERS_OF_THE_ABNORMAL(502,"参数异常");

    private int code;
    private String message;

    CodeEnum(int code, String message) {
        this.code = code;
        this.message = message;
    }

    public int getCode()
    {
        return this.code;
    }

    public String getMessage() {
        return this.message;
    }
}
